package com.example.demo.web.rest.evt;

import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;

import javax.validation.constraints.NotNull;
import java.io.Serializable;

/**
 * Description:
 *
 * @Author zmf
 * @Date 2018/12/19  16:10
 */
@ApiModel("资源权限参数")
public class ResourceEvt implements Serializable{
    private static final long serialVersionUID = -196227936069315126L;
    @ApiModelProperty("关联资源主键")
    @NotNull
    private String resourceKey;
    @ApiModelProperty("资源类型")
    @NotNull
    private Integer resourceType;
    @ApiModelProperty(value = "已分配的操作权限,json格式的字符串",notes = "[{\"key\": \"edit\",\"name\": \"修改\"},{\"key\": \"delete\",\"name\": \"删除\"}]")
    private String operationCode;

    public String getResourceKey() {
        return resourceKey;
    }

    public void setResourceKey(String resourceKey) {
        this.resourceKey = resourceKey;
    }

    public Integer getResourceType() {
        return resourceType;
    }

    public void setResourceType(Integer resourceType) {
        this.resourceType = resourceType;
    }

    public String getOperationCode() {
        return operationCode;
    }

    public void setOperationCode(String operationCode) {
        this.operationCode = operationCode;
    }

    @Override
    public String toString() {
        return "ResourceEvt{" +
            "resourceKey=" + resourceKey +
            ", resourceType=" + resourceType +
            ", operationCode='" + operationCode + '\'' +
            '}';
    }
}
